Conversation
|
rustbot has assigned @dingxiangfei2009. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
cc @Zalathar |
| let is_all_def_kind = |def_kind| { | ||
| stack.iter().all(|entry| match entry.node.tagged_key { | ||
| TaggedQueryKey::type_of(def_id) | ||
| | TaggedQueryKey::explicit_implied_predicates_of(def_id) |
There was a problem hiding this comment.
Why does this condition contain the type_of and explicit_implied_predicates_of queries specifically?
The previous logic didn't contain any specific queries.
There was a problem hiding this comment.
These are the queries which are involved in simple TyAlias / TraitAlias cycles (in our tests at least).
There was a problem hiding this comment.
This needs a comment and probably a panic if we reach this code with any other TaggedQueryKey.
There was a problem hiding this comment.
It looks like the surrounding function is called to produce a diagnostic for any query cycle, and this particular snippet is doing a best-effort check for certain situations that would let us add more specific information to that diagnostic.
So a panic here seems inappropriate.
This comment has been minimized.
This comment has been minimized.
0838a5f to
6308ab9
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
6308ab9 to
e6098df
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
This removes
TaggedQueryKey::def_kindby accessing the relevant query keys directly.